package redis;

import redis.clients.jedis.Jedis;
import redis.clients.jedis.Transaction;

public class JedisTestTransaction {

    public static void main(String[] args) {


        //连接redis
        Jedis jedis = new Jedis("192.168.153.128",6379);

        //获取事务对象
        Transaction multi = jedis.multi();
        multi.set("k6","v6");
        multi.set("k7","v7");
        multi.exec();

    }




}
